package com.shixi.shixitraining.shixitraining.ui.tabhome.fragment;

import android.os.Bundle;
import android.widget.TextView;

import com.shixi.shixitraining.shixitraining.R;
import com.shixi.shixitraining.shixitraining.base.TabhostBaseFragment;
import com.shixi.shixitraining.shixitraining.ui.tabhome.entity.AuthenBean;

import java.util.List;

/**
 * Created by shenyan on 2018/8/15.
 */

public class CourseDescriptionFragment extends TabhostBaseFragment {
    private List<AuthenBean.DataBean.CurriculumBean> curriculumData;


    @Override
    protected int getlayoutId() {
        return R.layout.fragment_course_description;
    }

    @Override
    protected void initPager() {

        Bundle arguments = getArguments();

        TextView mDesciptionTv = (TextView) mContentView.findViewById(R.id.tv_description);
        if (arguments!=null){
            AuthenBean mData = (AuthenBean) arguments.getSerializable("bean");
            AuthenBean.DataBean data = mData.getData();

            String describe = data.getDescribe();

           mDesciptionTv.setText(describe);
        }


    }

//    private void initView() {
//
//        RecyclerView coureseRcview = (RecyclerView) mContentView.findViewById(R.id.course_rcview);
//
//        LinearLayoutManager manager=new LinearLayoutManager(getContext());
//        manager.setOrientation(LinearLayoutManager.VERTICAL);
//        coureseRcview.setLayoutManager(manager);
//
//        CourseDescriptionAdapter  adapter=new CourseDescriptionAdapter(getContext(),curriculumData);
//        coureseRcview.setAdapter(adapter);
//    }


//    class  CourseDescriptionAdapter  extends BaseAdapter<AuthenBean.DataBean.CurriculumBean>{
//
//
//        public CourseDescriptionAdapter(Context context, List<AuthenBean.DataBean.CurriculumBean> data) {
//            super(context, data);
//        }
//
//
//        @Override
//        public void convert(BaseRecycleHolder holder, AuthenBean.DataBean.CurriculumBean item, int position) {
//
//            holder.setText(R.id.tv_course_title,item.getContent());
//            holder.setText(R.id.tv_course_content,item.getContent());
//
//        }
//
//        @Override
//        protected int getLayoutId(int viewType) {
//            return R.layout.adapter_course;
//        }
//
//
//    }


}
